package com.example.interview.service;

import com.example.interview.mapper.UserMapper;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.math.BigDecimal;

@Service
public class UserService {
    @Resource
    UserMapper mapper;

    public BigDecimal queryBalance(long userId) {
        return mapper.queryBalance(userId);
    }

    public void setMoney(long userId, BigDecimal total) {
        mapper.setMoney(userId, total);
    }
}
